#pragma once

class Canvas;

class Drawable
{
public:
	virtual ~Drawable() {};

	virtual void Draw(Canvas& canvas) = 0;
};

class Decorator : public Drawable
{
public:
	Decorator(Drawable& drawable) : m_drawable(drawable)
	{
	}

	void Draw(Canvas& canvas)
	{
		m_drawable.Draw(canvas);
		DrawDecoration(canvas);
	}

protected:
	// draw decorated interface
	virtual void DrawDecoration(Canvas& canvas) = 0; // pure virtual
	Drawable& m_drawable;
};